import request from '@/utils/request'

// 获取积分信息
export const getPointsInfo = () => {
  return request({
    url: '/points/today',
    method: 'GET'
  })
}

// 获取积分记录
export const getPointsRecords = (params) => {
  return request({
    url: '/points/records',
    method: 'GET',
    params
  })
}

// 生成奖励图片
export const generateImage = () => {
  return request({
    url: '/image/generate',
    method: 'POST'
  })
}

// 获取图片记录
export const getImageRecords = (params) => {
  return request({
    url: '/image/records',
    method: 'GET',
    params
  })
}

// 删除图片记录
export const deleteImage = (id) => {
  return request({
    url: `/image/records/${id}`,
    method: 'DELETE'
  })
} 